package com.fary.annotarion;

import org.springframework.core.annotation.AliasFor;

import java.lang.annotation.*;

/**
 * 这时@MyAnnotationB(“vvv”)就和@MyAnnotationA(a2=“vvv”)等价。
 */
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.TYPE)
@Documented
@MyAnnotationA
public @interface MyAnnotationB {

    @AliasFor(annotation = MyAnnotationA.class, value = "a2")
    String value() default "";

}
